package com.demo.springcloud.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.ResponseBody;

@Controller
@RequestMapping("/double")
public class DoubleController {

    @RequestMapping("/2")
    @ResponseBody
    public Integer doubleCount(@RequestParam(value = "count") Integer count){
        return count * 2;
    }
    @RequestMapping("/3")
    @ResponseBody
    public Integer tripleCount(@RequestParam(value = "count")Integer count){
        return count * 3;
    }
}
